package com.ruoyi.qd.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;

@Data
public class OrderAppointmentReq {
    @NotNull(message = "用户id不能为空")
    private Long userId;

    @NotNull(message = "机器人id不能为空")
    private Long robotId;

    @NotNull(message = "交易金额不能为空")
    @DecimalMin(value = "0.01", message = "交易金额必须大于0.01")
    private BigDecimal amount;

    @NotNull(message = "交易类型不能为空")
    private String type;

    @NotNull(message = "预约时间不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date appointmentTime;
}
